(undo): Pass proper arg to delete-auto-save-file-if-necessary.
authorRichard M. Stallman <rms@gnu.org>
Tue, 1 Jun 1993 20:31:47 +0000 (20:31 +0000)
committerRichard M. Stallman <rms@gnu.org>
Tue, 1 Jun 1993 20:31:47 +0000 (20:31 +0000)
lisp/simple.el

index 72bca14e651e4d7e5dc203787420c3de622fb84c..a2b900d5b5a6d62dbc1a366fb4dfdd5a76c4f08f 100644 (file)
@@ -597,7 +597,8 @@ Get previous element of history which is a completion of minibuffer contents."
 Repeat this command to undo more changes.
 A numeric argument serves as a repeat count."
   (interactive "*p")
-  (let ((modified (buffer-modified-p)))
+  (let ((modified (buffer-modified-p))
+       (recent-save (recent-auto-save-p)))
     (or (eq (selected-window) (minibuffer-window))
        (message "Undo!"))
     (or (eq last-command 'undo)
@@ -606,7 +607,7 @@ A numeric argument serves as a repeat count."
     (setq this-command 'undo)
     (undo-more (or arg 1))
     (and modified (not (buffer-modified-p))
-        (delete-auto-save-file-if-necessary))))
+        (delete-auto-save-file-if-necessary recent-save))))
 
 (defvar pending-undo-list nil
   "Within a run of consecutive undo commands, list remaining to be undone.")